package com.yx.changdao.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.yx.changdao.common.data.Result;
import com.yx.changdao.common.entity.SysRole;
import com.yx.changdao.common.exception.AlertException;
import com.yx.changdao.common.vo.RolePermissionSetVo;

/**
 * @Description: 权限设置
 * @Auther: zhangcongzhen
 * @create 2020/4/17
 */
public interface SysPermissionSetService extends IService<SysRole> {
    /**
     * 权限设置列表
     * @param page
     * @param limit
     * @return
     */
    Result getResult(Long page, Integer limit);

    /**
     * 添加
     * @return
     * @throws AlertException
     */
    Result add(RolePermissionSetVo rolePermissionSetVo) throws AlertException;
    /**
     * 更新
     * @return
     * @throws AlertException
     */
    Result update(RolePermissionSetVo rolePermissionSetVo) throws AlertException;
    /**
     * 删除
     * @param roleId
     * @return
     * @throws AlertException
     */
    Result delete(String roleId) throws AlertException;

    /**
     * 角色及角色拥有的权限列表
     * @param roleId
     * @return
     * @throws AlertException
     */
    Result getRolePermission(String roleId) throws AlertException;
}
